$path = "$env:USERPROFILE\documents\WindowsPowerShell" $curpath = Split-Path $MyInvocation.MyCommand.Path if(-not (test-path $path)) { md $path } xcopy /y $curpath\Microsoft.PowerShell_profile.ps1 $path xcopy /s/e/y/i $curpath\Autoload $path\Autoload Write-Host -ForegroundColor Red @" Please restart your command prompt to use latest script version. "@ Write-Host -ForegroundColor White @" "@